Package slides.workingwithslide

Source Code of slides.workingwithslide.AsposeSlideTitle

package slides.workingwithslide;

import com.aspose.slides.IAutoShape;
import com.aspose.slides.ISlide;
import com.aspose.slides.Presentation;
import com.aspose.slides.SaveFormat;

public class AsposeSlideTitle
{
  public static void main(String[] args)
  {
    //Create a presentation
      Presentation pres = new Presentation();

      //Add the title slide
      ISlide slide = pres.getSlides().addEmptySlide(pres.getLayoutSlides().get_Item(0));


      //Set the title text
      ((IAutoShape)slide.getShapes().get_Item(0)).getTextFrame().setText("Slide Title Heading");

      //Set the sub title text
      ((IAutoShape)slide.getShapes().get_Item(1)).getTextFrame().setText("Slide Title Sub-Heading");

      //Write output to disk
      pres.save("data/Aspose_SlideTitle.pptx",SaveFormat.Pptx);
  }
}
TOP

Related Classes of slides.workingwithslide.AsposeSlideTitle

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.